﻿@using Lari.Configuration
@using Lari.Web.Utility
@model Lari.Services.ViewModel.UserMgrGlanceModel
<div id="pagecontent">
    <div style="float: left; width: 48%">
        <p>
            <h2>
                What is User Management?</h2>
        </p>
        <p align="justify">
            Most security-conscious enterprises today implement some form of authentication
            and authorization for accessing application resources. The benefits to this approach
            are clear – user permissions can be verified before granting access to resources.
        </p>
        <img src="@Url.Content("~/Image/user_management.png")"/>
    </div>
    <div style="float: right; width: 48%">
        <div class="doubleSpacer">
        </div>
        @if (this.HasAccess(AccessConst.User.AdminGlance))
        { 
            <div class="tab">
                Adnin Glance</div>
            
            <div class="tabContent">
                <table>
                    <tr>
                        <td>
                            Total Employees:
                        </td>
                        <td>
                            &nbsp;
                        </td>
                        <td>
                            <strong>@(Model.ActiveEmployees+Model.InActiveEmployees)</strong>
                        </td>
                    </tr>
                    <tr>
                        <td>
                            &nbsp;
                        </td>
                        <td>
                            Activev:
                        </td>
                        <td>
                            <strong>@Model.ActiveEmployees</strong>
                        </td>
                    </tr>
                    <tr>
                        <td>
                            &nbsp;
                        </td>
                        <td>
                            Inactive:
                        </td>
                        <td>
                            <strong>@Model.InActiveEmployees</strong>
                        </td>
                    </tr>
                    <tr>
                        <td>
                            Total Users:
                        </td>
                        <td>
                            &nbsp;
                        </td>
                        <td>
                            <strong>@(Model.ActiveUsers+Model.InactiveUsers)</strong>
                        </td>
                    </tr>
                    <tr>
                        <td>
                            &nbsp;
                        </td>
                        <td>
                            Active:
                        </td>
                        <td>
                            <strong>@Model.ActiveUsers</strong>
                        </td>
                    </tr>
                    <tr>
                        <td>
                            &nbsp;
                        </td>
                        <td>
                            Inactive:
                        </td>
                        <td>
                            <strong>@Model.InactiveUsers</strong>
                        </td>
                    </tr>
                    <tr>
                        <td>
                            Employees not mapped as user
                        </td>
                        <td>
                            &nbsp;
                        </td>
                        <td>
                            <strong>@Model.NoMappedEmployees</strong>
                        </td>
                    </tr>
                    <tr>
                        <td colspan="2">
                            Hint Questions & Answer to recover password not provided:
                        </td>
                        <td>
                            <strong>@Model.NoHintQuestionEmployees</strong>
                        </td>
                    </tr>
                </table>
            </div>
            <div class="doubleSpacer">
            </div>
        }
        @if (!Model.IsCurrentUserHasHintQuestion)
        {
            <div class="tab">
                User Glance</div>
            <div class="tabContent">
                <p>
                    <strong>You have not provided Hint Questions & Answer to recover password.</strong></p>
                <p>@Html.ActionLink(ScreenName.Core.ChangeHintQuestion, ActionConst.ChangeHintQuestion, ControllerConst.Core)</p>
            </div>
        }
    </div>
    <div class="clear">
    </div>
</div>
